﻿using System;
using System.CodeDom;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Input;
using Newtonsoft.Json.Linq;

namespace CLVisionMES
{
    [Serializable]
    internal class DataGridComment : INotifyPropertyChanged
    {
        public event PropertyChangedEventHandler PropertyChanged;

        private LanguageComment _languageComments;

        public LanguageComment LanguageComments
        {
            get { return _languageComments; }
            set
            {
                _languageComments = value;
                this.PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(nameof(LanguageComments)));
            }
        }



        public ObservableCollection<object> ValueList { get; set; }

        public DataGridComment()
        {
            LanguageComments = new LanguageComment();
            ValueList = new ObservableCollection<object>();
        }



        public DataGridComment Clone()
        {
            // 创建一个新的 DataGridComment 对象并复制属性
            return new DataGridComment
            {
                LanguageComments = this.LanguageComments,
                ValueList = this.ValueList
            };
        }
    }

    [Serializable]
    internal class LanguageComment : INotifyPropertyChanged
    {

        private Dictionary<string, string> _languageCommentsDic;
        public Dictionary<string, string> LanguageCommentsDic
        {
            get { return _languageCommentsDic; }
            set { _languageCommentsDic = value; }
        }


        public LanguageComment()
        {
            _languageCommentsDic = new Dictionary<string, string>();
        }
        //private string _chineseComment;
        //public string ChineseComment
        //{
        //    get { return _chineseComment; }
        //    set { _chineseComment = value; }
        //}

        //private string _englishComment;

        //public string EnglishComment
        //{
        //    get { return _englishComment; }
        //    set { _englishComment = value; }
        //}

        //private string _germanComment;

        //public string GermanComment
        //{
        //    get { return _germanComment; }
        //    set { _germanComment = value; }
        //}



        public event PropertyChangedEventHandler PropertyChanged;

        public LanguageComment Clone()
        {
            // 创建一个新的 DataGridComment 对象并复制属性
            return new LanguageComment
            {
                LanguageCommentsDic = this.LanguageCommentsDic
            };
        }
    }
}
